<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
    xmlns:s="http://jboss.com/products/seam/taglib"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:rich="http://richfaces.org/rich"
    template="layout/template.xhtml">

    <ui:define name="body">
    
    	<table align="right">
			<tr>
				<td>
					<h:commandButton immediate="true"
						onclick="abrirPopup('help_online/help_esqueci_senha.seam');" 
						title="Ajuda Online"
						alt="Ajuda Online"
						image="img/help_peq.jpg"/>
				</td>
			</tr>
		</table>
        
        <h2 class="title"><a href="#">Esqueci minha senha</a></h2><br/>
        
        <div>
        	<p>Nota: Informe o seu e-mail cadastrado conosco e lhe será enviada uma nova senha de acesso.</p>
        </div>
	        
       	<h:form id="formEsqueciSenha">
        	<h:panelGrid columns="1">
       			<s:decorate template="/layout/edit.xhtml">
           			<ui:define name="label">E-mail:</ui:define>
           			<h:inputText value="#{acessoClienteController.email}"
           				size="60"
           				validator="validadorEmail"
           				required="true" 
           				maxlength="200"/>
           		</s:decorate>
           		
           		<s:decorate template="/layout/edit.xhtml">
           			<s:graphicImage value="#{acessoClienteController.recuperaImagemCaptcha()}" />
           		</s:decorate>
           		
       			<s:decorate template="/layout/edit.xhtml">
           			<ui:define name="label">Código validação</ui:define>
           			<s:fragment>
	           			<h:inputText value="#{acessoClienteController.captcha}"
	           				id="verifyCaptcha"
	           				size="30"
	           				required="true" 
	           				maxlength="50">
	           			</h:inputText>
           			</s:fragment>
           		</s:decorate>
           		
        	</h:panelGrid>
        	
        	<div class="actionButtons">
	            <h:commandButton id="submit" value="Enviar senha" 
	            	action="#{acessoClienteController.enviarSenha()}"
	            	onclick="javascript:if(!confirm('Tem certeza que deseja enviar a nova senha?'))return false;#{rich:component('carregando')}.show()"/>
	            <h:commandButton id="voltar" value="Voltar" 
	            	onclick="#{rich:component('carregando')}.show()"
	            	immediate="true"
	            	action="home"/>
	        </div>	
	        
        </h:form>

    </ui:define>
</ui:composition>
